subplot(1,2,1)
[x0,y0] = meshgrid(1:0.02:2);
z0 = sin(x0).*sin(y0);
mesh(x0,y0,z0),xlabel('x'),ylabel('y'),zlabel('z');title('reference solution');
subplot(1,2,2)
res = [
1,1.06786,0.737271;
1,1,0.708073;
1.075,1,0.74015;
1.06333,1.09233,0.775722;
1,1.13622,0.763257;
1.1195,1.05871,0.784165;
1.06224,1.16591,0.80279;
1.14949,1,0.767889;
1.1237,1.12511,0.813564;
1,1.2051,0.785829;
1.18648,1.07594,0.815969;
1.12478,1.19888,0.840471;
1.06237,1.23756,0.825442;
1.22347,1,0.791223;
1.18697,1.15852,0.84952;
1,1.27449,0.804801;
1.26379,1.06502,0.833849;
1.12533,1.27193,0.862401;
1.23947,1.12392,0.852536;
1.18932,1.23384,0.875936;
1.06254,1.30876,0.843772;
1.29694,1,0.810113;
1.25954,1.19298,0.884961;
1.30175,1.12679,0.870521;
1,1.34439,0.819996;
1.18862,1.30796,0.895982;
1.12544,1.34419,0.879378;
1.33552,1.06324,0.849839;
1.25208,1.27225,0.907608;
1.06266,1.37988,0.857774;
1.33967,1.18984,0.903625;
1.3699,1,0.824547;
1.37386,1.12531,0.884946;
1.30926,1.24508,0.915;
1.18858,1.38047,0.911078;
1,1.4148,0.831253;
1.25188,1.34474,0.925407;
1.12553,1.41598,0.891698;
1.40767,1.06206,0.861756;
1.31498,1.30846,0.934354;
1.41399,1.18688,0.915836;
1.38099,1.26146,0.935652;
1.06272,1.45113,0.867432;
1.44235,1,0.834539;
1.44573,1.12263,0.89418;
1.25183,1.41731,0.938393;
1.18851,1.45258,0.921331;
1.31561,1.38176,0.950382;
1,1.48571,0.838427;
1.12551,1.48776,0.89937;
1.38069,1.34511,0.957121;
1.47933,1.06095,0.869158;
1.4605,1.24194,0.940624;
1.48441,1.17965,0.920956;
1.06272,1.5228,0.872669;
1.25132,1.48964,0.946268;
1.44889,1.31239,0.959646;
1.31495,1.45479,0.960943;
1.51429,1,0.840128;
1.18816,1.52461,0.926683;
1.5162,1.12051,0.898946;
1.37926,1.42004,0.970585;
1,1.55765,0.841398;
1.12534,1.55974,0.902346;
1.51925,1.22652,0.939835;
1.44464,1.38638,0.975237;
1.5164,1.28452,0.957849;
1.55033,1.06031,0.872309;
1.31367,1.52723,0.966197;
1.5519,1.17915,0.924066;
1.25035,1.56177,0.949042;
1.06267,1.59496,0.873395;
1.37751,1.493,0.978405;
1.51056,1.35484,0.97499;
1.18756,1.59667,0.92713;
1.5852,1,0.841384;
1.44187,1.45932,0.985541;
1.5864,1.12019,0.900047;
1.58375,1.2474,0.94822;
1,1.6301,0.839992;
1.12513,1.632,0.900616;
1.31185,1.5994,0.966248;
1.50656,1.42665,0.987577;
1.57604,1.32426,0.969732;
1.37541,1.56537,0.980949;
1.62107,1.06016,0.87132;
1.24898,1.63369,0.946761;
1.62224,1.18084,0.923684;
1.43939,1.53168,0.990613;
1.06269,1.66758,0.869566;
1.18694,1.66859,0.922766;
1.57101,1.39516,0.984589;
1.50358,1.49853,0.995126;
1.65561,1,0.838446;
1.64045,1.29904,0.960878;
1.65737,1.12037,0.896872;
1.37279,1.63771,0.978256;
1.66053,1.23827,0.941339;
1.30936,1.67132,0.961119;
1,1.70306,0.834121;
1.12523,1.70453,0.894283;
1.4368,1.60398,0.990483;
1.56763,1.46609,0.994498;
1.63422,1.36532,0.97694;
1.24729,1.70481,0.939578;
1.69186,1.0603,0.866102;
1.50094,1.5705,0.997552;
1.69406,1.18043,0.917718;
1.06287,1.74068,0.861162;
1.18697,1.7398,0.913974;
1.6943,1.28315,0.951334;
1.63099,1.43439,0.988879;
1.56498,1.53746,0.999412;
1.36927,1.71034,0.970229;
1.43382,1.67671,0.98508;
1.69378,1.33698,0.965329;
1.72551,1,0.83142;
1.72907,1.12098,0.889255;
1.30561,1.74252,0.95081;
1.72847,1.24,0.933983;
1,1.77653,0.823725;
1.49837,1.64287,0.994785;
1.12633,1.77814,0.883486;
1.62861,1.50486,0.996135;
1.24541,1.77292,0.928133;
1.69275,1.40296,0.978567;
1.56266,1.60928,0.999217;
1.76284,1.06063,0.856605;
1.76697,1.18322,0.908068;
1.74803,1.30259,0.949049;
1.43011,1.75038,0.974208;
1.06271,1.81382,0.84797;
1.36383,1.78416,0.956479;
1.19015,1.80917,0.90208;
1.69142,1.47238,0.987894;
1.62658,1.57606,0.998414;
1.49571,1.7161,0.986682;
1.75238,1.36985,0.963704;
1.29825,1.81167,0.935221;
1.7949,1,0.820429;
1.80166,1.12181,0.876959;
1.56059,1.68175,0.993799;
1.80683,1.25366,0.923951;
1,1.85051,0.808767;
1.12963,1.85996,0.866861;
1.68997,1.54302,0.9925;
1.24376,1.8289,0.915363;
1.75309,1.43927,0.974895;
1.62486,1.64784,0.995567;
1.42536,1.825,0.957668;
1.83432,1.06116,0.842748;
1.49291,1.79106,0.972919;
1.81184,1.33296,0.943734;
1.84188,1.18357,0.892116;
1.35436,1.86551,0.934748;
1.05716,1.87648,0.830318;
1.20835,1.87426,0.892244;
1.55887,1.75519,0.982989;
1.75264,1.50974,0.981652;
1.68861,1.61427,0.992113;
1.27636,1.87564,0.912777;
1.81402,1.40474,0.957183;
1.86378,1,0.805614;
1.62358,1.72036,0.987457;
1.87519,1.12212,0.859534;
1.87386,1.29799,0.919097;
1.87645,1.2364,0.900595;
1,1.925,0.789235;
1.09333,1.93266,0.830567;
1.16896,1.93405,0.860285;
1.49,1.87183,0.952075;
1.42117,1.88793,0.939318;
1.75181,1.58071,0.983594;
1.81458,1.47576,0.966026;
1.68752,1.68604,0.986594;
1.55775,1.82915,0.966743;
1.90779,1.06282,0.824479;
1.87523,1.36936,0.934703;
1.31232,1.93605,0.903007;
1.24095,1.93676,0.883416;
1.92431,1.18509,0.869368;
1.62307,1.79413,0.973846;
1.38331,1.93817,0.916908;
1.81438,1.54678,0.97018;
1.75098,1.65206,0.980548;
1.9353,1.26222,0.890118;
1.87615,1.44099,0.945695;
1.06786,2,0.796699;
1.13622,2,0.824779;
1.68686,1.7583,0.975849;
1.93214,1,0.78713;
1.94143,1.11886,0.838218;
1.45293,1.93964,0.926247;
1.93708,1.33368,0.907517;
1.55744,1.89086,0.948923;
1.2051,2,0.849171;
1,2,0.765147;
1.81391,1.61792,0.969498;
1.62437,1.87323,0.953375;
1.87641,1.51234,0.952018;
1.27449,2,0.869672;
1.75027,1.72394,0.972405;
1.34439,2,0.886091;
1.52269,1.94039,0.931369;
1.93784,1.40567,0.920685;
2,1.22347,0.855;
2,1.075,0.799809;
1.68698,1.82981,0.960084;
2,1.14949,0.829784;
1.4148,2,0.898255;
2,1.29694,0.875412;
1.87629,1.58347,0.953609;
1.81342,1.68941,0.963875;
1.93817,1.47748,0.929205;
1.74945,1.79638,0.959125;
1.59241,1.94062,0.932139;
1.48571,2,0.906008;
2,1,0.765147;
2,1.3699,0.891009;
1.69053,1.88943,0.942621;
1.87604,1.65458,0.950415;
1.93823,1.54883,0.933018;
1.66209,1.93988,0.928734;
1.81287,1.76181,0.95317;
2,1.44235,0.901806;
1.55765,2,0.909219;
1.747,1.86838,0.941192;
1.93817,1.61975,0.932149;
1.87575,1.72608,0.942368;
2,1.51429,0.907846;
1.6301,2,0.907699;
1.81195,1.83664,0.936949;
1.73171,1.93656,0.92174;
1.93805,1.69052,0.926626;
2,1.5852,0.909203;
1.8754,1.79865,0.929285;
1.70306,2,0.901355;
1.8105,1.92209,0.912267;
2,1.65561,0.906029;
1.9379,1.76146,0.916444;
1.87538,1.87296,0.910694;
1.77653,2,0.890121;
2,1.72551,0.898436;
1.9376,1.83312,0.901509;
1.87963,1.9404,0.888049;
1.85051,2,0.873957;
2,1.7949,0.88656;
1.93634,1.90705,0.88153;
2,1.86378,0.87055;
1.925,2,0.852851;
2,1.93214,0.850576;
2,2,0.826822;
];
T = [
1,2,3;
1,3,4;
1,4,5;
3,6,4;
7,5,4;
3,8,6;
4,6,9;
7,4,9;
7,10,5;
6,8,11;
9,6,11;
7,9,12;
7,13,10;
12,13,7;
8,14,11;
11,15,9;
15,12,9;
16,10,13;
17,11,14;
18,13,12;
11,19,15;
11,17,19;
15,20,12;
21,16,13;
18,12,20;
21,13,18;
17,14,22;
15,19,23;
15,23,20;
17,24,19;
21,25,16;
18,20,26;
21,18,27;
23,19,24;
17,22,28;
17,28,24;
26,27,18;
20,23,29;
20,29,26;
21,30,25;
30,21,27;
23,24,31;
28,22,32;
28,33,24;
23,34,29;
31,24,33;
35,27,26;
23,31,34;
36,25,30;
37,26,29;
38,30,27;
37,35,26;
39,28,32;
33,28,39;
38,27,35;
34,40,29;
33,41,31;
37,29,40;
34,31,42;
43,36,30;
43,30,38;
42,31,41;
39,32,44;
34,42,40;
39,45,33;
37,46,35;
45,41,33;
38,35,47;
48,37,40;
43,49,36;
46,47,35;
43,38,50;
48,46,37;
51,40,42;
39,44,52;
47,50,38;
39,52,45;
41,53,42;
51,48,40;
45,54,41;
43,55,49;
50,55,43;
41,54,53;
46,56,47;
42,57,51;
48,58,46;
53,57,42;
44,59,52;
60,50,47;
45,52,61;
58,56,46;
45,61,54;
51,62,48;
60,47,56;
63,49,55;
48,62,58;
64,55,50;
65,53,54;
64,50,60;
57,66,51;
67,57,53;
68,52,59;
51,66,62;
61,52,68;
58,69,56;
65,67,53;
54,61,70;
71,60,56;
65,54,70;
72,63,55;
72,55,64;
73,58,62;
71,56,69;
57,74,66;
67,74,57;
64,60,75;
73,69,58;
68,59,76;
77,62,66;
71,75,60;
68,78,61;
70,61,78;
79,67,65;
62,77,73;
79,65,70;
72,80,63;
72,64,81;
64,75,81;
69,82,71;
83,66,74;
67,84,74;
83,77,66;
73,85,69;
68,76,86;
79,84,67;
68,86,78;
75,71,87;
85,82,69;
78,88,70;
79,70,88;
77,89,73;
82,87,71;
72,90,80;
81,90,72;
81,75,91;
89,85,73;
74,92,83;
92,74,84;
87,91,75;
77,83,93;
76,94,86;
79,95,84;
93,89,77;
78,86,96;
78,96,88;
97,82,85;
98,79,88;
99,87,82;
90,100,80;
101,90,81;
98,95,79;
101,81,91;
102,85,89;
92,103,83;
99,82,97;
103,93,83;
92,84,104;
105,91,87;
104,84,95;
102,97,85;
106,86,94;
86,106,96;
107,89,93;
105,87,99;
108,88,96;
108,98,88;
102,89,107;
109,100,90;
101,109,90;
110,101,91;
98,111,95;
110,91,105;
112,103,92;
104,112,92;
113,93,103;
97,114,99;
113,107,93;
115,97,102;
104,95,116;
106,94,117;
106,118,96;
95,111,116;
108,96,118;
99,119,105;
97,115,114;
120,98,108;
120,111,98;
109,121,100;
122,102,107;
99,114,119;
101,123,109;
110,123,101;
124,103,112;
115,102,122;
113,103,124;
125,110,105;
112,104,126;
116,126,104;
127,107,113;
125,105,119;
106,117,128;
106,128,118;
108,118,129;
127,122,107;
120,108,129;
130,116,111;
131,114,115;
120,130,111;
109,132,121;
123,132,109;
114,133,119;
110,134,123;
125,134,110;
124,112,135;
136,113,124;
112,126,135;
137,115,122;
127,113,136;
114,131,133;
138,126,116;
131,115,137;
139,125,119;
138,116,130;
117,140,128;
118,128,141;
118,141,129;
142,122,127;
139,119,133;
120,129,143;
120,143,130;
144,121,132;
145,132,123;
142,137,122;
134,145,123;
124,135,146;
136,124,146;
147,134,125;
148,135,126;
147,125,139;
149,127,136;
148,126,138;
150,133,131;
142,127,149;
151,128,140;
141,128,151;
152,131,137;
138,130,153;
154,129,141;
153,130,143;
154,143,129;
139,133,155;
156,144,132;
145,156,132;
150,131,152;
134,157,145;
142,158,137;
150,155,133;
157,134,147;
159,146,135;
136,146,160;
159,135,148;
160,149,136;
147,139,161;
152,137,158;
148,138,162;
138,153,162;
151,140,163;
142,149,164;
139,155,161;
151,165,141;
154,141,165;
143,166,153;
142,164,158;
154,167,143;
157,147,161;
156,168,144;
145,169,156;
170,145,157;
150,152,171;
143,167,166;
172,155,150;
159,173,146;
160,146,173;
159,148,174;
145,170,169;
175,149,160;
148,162,174;
152,158,176;
175,164,149;
151,163,177;
171,172,150;
151,177,165;
169,168,156;
153,178,162;
161,155,179;
153,166,178;
161,180,157;
171,152,176;
181,154,165;
181,167,154;
164,182,158;
170,157,180;
172,183,155;
176,158,182;
159,184,173;
183,179,155;
159,174,184;
160,173,185;
166,167,186;
161,179,180;
175,160,185;
162,187,174;
169,188,168;
162,178,187;
169,170,189;
190,164,175;
177,163,191;
181,186,167;
177,192,165;
164,190,182;
171,193,172;
166,194,178;
165,192,181;
171,176,195;
169,189,188;
180,196,170;
166,186,194;
172,193,183;
168,188,197;
170,196,189;
173,184,198;
173,198,185;
176,182,199;
174,200,184;
180,179,201;
174,187,200;
175,185,202;
183,203,179;
190,175,202;
171,204,193;
195,204,171;
187,178,205;
176,199,195;
181,206,186;
177,191,207;
207,192,177;
180,201,196;
178,194,205;
208,182,190;
192,209,181;
203,201,179;
183,193,210;
208,199,182;
194,186,211;
184,212,198;
181,209,206;
183,210,203;
184,200,212;
185,198,213;
185,213,202;
187,214,200;
186,206,211;
187,205,214;
215,190,202;
207,209,192;
195,199,216;
208,190,215;
204,217,193;
195,216,204;
207,191,218;
194,219,205;
193,217,210;
194,211,219;
208,220,199;
198,212,221;
198,221,213;
212,200,222;
222,200,214;
199,223,216;
202,213,224;
215,202,224;
220,223,199;
214,205,225;
204,216,226;
204,226,217;
205,219,225;
227,208,215;
227,220,208;
212,228,221;
212,222,228;
213,221,229;
214,230,222;
213,229,224;
214,225,230;
223,231,216;
232,215,224;
216,231,226;
232,227,215;
220,233,223;
220,227,233;
228,234,221;
229,221,234;
228,222,235;
222,230,235;
224,229,236;
223,237,231;
232,224,236;
223,233,237;
238,227,232;
238,233,227;
228,239,234;
228,235,239;
229,234,240;
229,240,236;
232,236,241;
238,232,241;
233,242,237;
238,242,233;
239,243,234;
240,234,243;
244,236,240;
244,241,236;
241,245,238;
238,246,242;
245,246,238;
240,243,247;
240,247,244;
244,248,241;
248,245,241;
244,247,249;
244,249,248;
250,246,245;
250,245,248;
248,249,251;
248,251,250;
250,251,252;
];
x=res(:,1);y=res(:,2);z=res(:,3);
trimesh(T,x,y,z);,xlabel('x'),ylabel('y'),zlabel('z');title('calculation result');